package com.yami.shop.mystery.common.model;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.yami.shop.bean.vo.CategoryVO;
import com.yami.shop.mystery.common.dto.MysteryBoxOpenRecordDto;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;
import java.util.List;

/**
 * 盲盒
 *
 * @author wxf
 * @date 2023/4/4 15:53
 */
@Data
@TableName("tz_mystery_box")
public class MysteryBox implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId
    private Long id;

    @Schema(description = "盲盒名称")
    private String boxName;

    @Schema(description = "店铺id")
    private Long shopId;

    @Schema(description = "原价（分）")
    private Double oriPrice;

    @Schema(description = "现价（分）")
    private Double price;

    @Schema(description = "商品卖点")
    private String brief;

    @Schema(description = "商品详情")
    private String content;

    @Schema(description = "商品视频")
    private String video;

    @Schema(description = "主图")
    private String pic;

    @Schema(description = "商品图片，以,分割")
    private String imgs;

    @Schema(description = "0 未删除 1已删除")
    private Integer isDelete;

    @Schema(description = "状态（0:失效、1:正常、2:违规下架、3:等待审核、4:审核失败）")
    private Integer status;

    @Schema(description = "总库存")
    private Long totalStocks;

    @Schema(description = "创建时间")
    private Date createTime;

    @Schema(description = "修改时间")
    private Date updateTime;

    @Schema(description = "是否推荐 1 是 0 否")
    private Long isRecommend;

    @Schema(description = "排序值")
    private Long recommendNum;

    @Schema(description = "分账ID")
    private Long divisionReceiverId;

    @Schema(description = "限购数量")
    private Long quota;

    @Schema(description = "创作者")
    private String author;

    @Schema(description = "创作者头像")
    private String authorImg;

    @Schema(description = "发行方")
    private String issue;

    @Schema(description = "购买需知")
    private String inform;

    @Schema(description = "活动规则")
    private String activityRules;

    @Schema(description = "稀有度")
    private Long levelId;

    @Schema(description = "空奖概率")
    private Double losingLottery;

    @Schema(description = "是否开启空奖 0-不开启 1-开启")
    private Long isLosingLottery;

    @Schema(description = "空奖库存")
    private Long losingLotteryStock;

    @Schema(description = "在平台当中的分类id")
    private Long categoryId;

    @Schema(description = "在店铺当中的分类id")
    private Long shopCategoryId;

    @Schema(description = "上架时间")
    private Date putawayTime;

    @Schema(description = "商品类型(0普通盲盒商品 1活动)")
    private Integer prodType;

    @Schema(description = "活动id(对应prod_type=1)")
    private Long activityId;

    @Schema(description = "销量")
    private Integer soldNum;

    @Schema(description = "注水销量")
    private Integer waterSoldNum;

    @Schema(description = "品牌Id")
    private Long brandId;

    @Schema(description = "链信息")
    private String chain;

    @Schema(description = "链接地址")
    private String linkAddr;

    @Schema(description = "二维码地址")
    private String qrcodeAddr;

    @TableField(exist = false)
    @Schema(description = "店铺名称")
    private String shopName;

    @TableField(exist = false)
    @Schema(description = "商品名字")
    private String prodName;

    @TableField(exist = false)
    @Schema(description = "盲盒盒子库存")
    private MysteryBoxSku boxSku;

    @TableField(exist = false)
    @Schema(description = "盲盒盒子商品信息")
    private List<MysteryBoxExtension> prods;

    @TableField(exist = false)
    @Schema(description = "分类信息")
    private CategoryVO categoryVO;

    @TableField(exist = false)
    @Schema(description = "店铺分类信息")
    private CategoryVO shopCategoryVO;

    @TableField(exist = false)
    @Schema(description = "用户持有数")
    private Integer myHold;

    @TableField(exist = false)
    @Schema(description = "已开数")
    private Integer myOpenNum;

    @TableField(exist = false)
    @Schema(description = "待开数")
    private Integer myStayNum;

    @TableField(exist = false)
    @Schema(description = "可用库存")
    private Long stocks;

    @TableField(exist = false)
    @Schema(description = "商铺编码")
    private String channelCode;

    @TableField(exist = false)
    @Schema(description = "链名称")
    private String chainName;

    @TableField(exist = false)
    @Schema(description = "是否拥有该链")
    private Boolean isOwnChain;

    @TableField(exist = false)
    @Schema(description = "批量修改盲盒状态id")
    private Long[] ids;

    @TableField(exist = false)
    @Schema(description = "开启状态（0:未开启、1:部分开启、2:已开启）")
    private Integer openStatus;

    @TableField(exist = false)
    @Schema(description = "盒子剩余数量")
    private Long boxCount;

    @TableField(exist = false)
    @Schema(description = "是否包含新的盒子")
    private String checkStatus;

}
